package com.sk.skop.demo.controller;

import com.sk.skop.demo.entity.Children;
import com.sk.skop.demo.entity.Dog;
import com.sk.skop.demo.entity.Person;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class PersonController {
    @Autowired
    private Person person;
    @Autowired
    private Dog dog;
    @Autowired
    private Children children;
    @GetMapping("/person")
    public String getPerson(){
        return person.toString();
    }
    @GetMapping("/dog")
    public String getDog(){return  dog.toString();}
    @GetMapping("children")
    public String getChildren(){return  children.toString();}
}
